import http from './base'
/***
 * 登录
 */
export function getNewsList(obj) {
  let { type } = obj;
  console.log(1121,obj)
  let url = "";
  if (Number(type) === 0) {
    url = '/mylist/hotList.json'
  } else if(Number(type) === 1) {
    url = '/mylist/myvideo.json'
  }else{
   url = '/mylist/myjs.json'
  }
  return http.post(url, obj);
}
export function getDetails(obj) {
  console.log('apis',obj)
  let { type } = obj;
  let url = "";
  if (Number(type) === 0) {
    url = '/mylist/hotListDetails.json'
  } else if(Number(type) === 1) {
    url = '/mylist/myvideoDetails.json'
  }else{
     url = '/mylist/myvideoDetails.json'
  }
  return http.post(url, obj);
}